package com.biz.primus.ms.tms.dao.po;

import com.biz.primus.ms.base.jpa.po.BaseEntity;
import lombok.Getter;
import lombok.Setter;

import javax.persistence.*;

/**
 * DeliveryItemPo
 *
 * @author JKLiues
 * @date 2017/11/21
 */
@Getter
@Setter
@Entity
@Table(name = "delivery_item")
public class DeliveryOrderItemPo extends BaseEntity {
    private static final long serialVersionUID = -6158254248071511043L;


    @ManyToOne(cascade = CascadeType.ALL, optional = false, fetch = FetchType.LAZY)
    @JoinColumn(name = "deliveryOrderId")
    private DeliveryOrderPo deliveryOrder;

    /**
     * 商品编号
     */
    @Column
    private String productCode;

    /**
     * 商品名称
     */
    @Column
    private String productName;

    /**
     * 商品价格
     */
    @Column
    private Integer price;

    /**
     * 商品数量
     */
    @Column
    private Integer quantity;

    /**
     * 商品总价
     */
    @Column
    private Integer totalAmount;

    /**
     * 组合商品编号
     */
    @Column
    private String groupItemCode;
}
